<?php 
header("Content-type: image/png");

// $dst = imageCreateTrueColor(500,300); 
// $color=imageColorAllocate($src,150,150,150);
// imageFill($src,0,0,$color);
$dst = imageCreateFrompng("./5915b2fb046fb.png"); 
$src = imageCreateFrompng("./IDR_PRODUCT_LOGO.png"); 

// $color = imageColorAllocate($src,mt_rand(0,255),mt_rand(0,255),mt_rand(0,255));
// imagefilledrectangle ( $src , 150 , 25 , 350 , 225, $color );


// echo imagesx($src);
// echo imagesy($src);
// imagecopy ( $dst, $src ,0,0,0,0, 200 , 200 );

imagecopymerge ( $dst , $src , 150 , 240 , 0, 0, 100 , 100, 50 );





//3输出
imagepng($dst);  


//4释放资源
imageDestroy($dst) ;

imageDestroy($src);





 ?>